<!DOCTYPE html>
<html lang="en">
<head>
  <meta charset="UTF-8">
  <meta name="viewport" content="width=device-width, initial-scale=1.0">
  <meta http-equiv="X-UA-Compatible" content="ie=edge">
  <title>Document</title>
  <style>
    .body {
      margin: 0;
    }
    .container {
      max-width: 800px;
      /* width: 70px; */
    }
    .container span {
      display: inline-block;
      width: 20px;
      height: 20px;
      background-color: #eee;
      border: 1px solid #aaa;
      box-sizing: border-box;
      margin: 1px;
      cursor: pointer;
      font-size: 13px;
      color: #666;
    }
  </style>
  <script src="./lib/sweep.js"></script>
  
</head>
<body>
  <div id="box">
    <input type="number" id="number">
    <input type="button" id="btn" value="确定">
    <div class="result"></div>
  </div>
</body>
</html>
<script>
  document.getElementById('btn').addEventListener('click', function() {
    console.log(document.getElementById('number').value)
    let s = new Sweep(document.getElementById('number').value)
    s.init()
  })
</script>